export const defaultState = {
    mnemonicStr: '',
    unSignTx: {},
    toAddress: '',
    lockVisible: false
}

export default singleSignReducer = (state = defaultState, action) => {
    switch (action.type) {
        case 'setMnemonicStr':
            return { ...state, mnemonicStr: action.value };
        case 'setunSignTx':
            return { ...state, unSignTx: action.value };
        case 'setToAddress':
            return { ...state, toAddress: action.value };
        case 'setLockVisible':
            return { ...state, lockVisible: action.value };
        default:
            return state
    }
}